package com.cbgolf.oa.event;

import com.cbgolf.oa.entity.MenuBean;
import com.cbgolf.oa.entity.ParkBean;
import com.cbgolf.oa.viewbean.OrderBean;
import java.util.List;

public class EventMenus {


  /**
   * 消息目的地
   */
  public int target;
  /**
   * 请求操作 refresh loadmore initdata
   */
  public int requestType;

  /**
   * error msg code
   */
  public String errorMsg;
  public int errorCode;

  public List<MenuBean> listMenus;
  public boolean hasOrderConfirmPermission;
  public boolean haveNotRead;
  public boolean isConfirmSuccess;
  public ParkBean parkBean;
  public OrderBean orderBean;

  public static class Builder {

    EventMenus bean;

    public Builder() {
      bean = new EventMenus();
    }

    public Builder setListMenus(List<MenuBean> list) {
      bean.listMenus = list;
      return this;
    }

    public Builder setRequestType(int type) {
      bean.requestType = type;
      return this;
    }

    public Builder setError(String error, int code) {
      bean.errorMsg = error;
      bean.errorCode = code;
      return this;
    }

    public Builder setTarget(int target) {
      bean.target = target;
      return this;
    }
    public Builder setHaveNotRead(boolean has) {
      bean.haveNotRead = has;
      return this;
    }
    public Builder setHasOrderConfirmPermission(boolean has) {
      bean.hasOrderConfirmPermission = has;
      return this;
    }
    public Builder setParkBean(ParkBean data) {
      bean.parkBean =data;
      return this;
    }
    public Builder setOrderBean(OrderBean data) {
      bean.orderBean = data;
      return this;
    }
    public Builder setIsConfirmSuccess(boolean isConfirmSuccess) {
      bean.isConfirmSuccess = isConfirmSuccess;
      return this;
    }

    public EventMenus build() {
      return bean;
    }
  }

}
